package cn.microservices.cloud.common.mybtis.core.dataobject;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;

@Data
public class BaseDO implements Serializable {
    private static final long serialVersionUID = 1L;
    /**
     * ID
     */
    @TableId(type = IdType.ASSIGN_UUID)
    private String id;
    /**
     * 插入时间
     */
    @TableField(value = "insert_time",fill = FieldFill.INSERT)
    private LocalDateTime insertTime;

    /**
     * 更新时间
     */
    @TableField(value = "update_time",fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateTime;

    /**
     * 是否有效
     */
    @TableField(fill = FieldFill.INSERT)
    private String availableFlag;



    /**
     * 插入用户
     */
    @TableField(value = "insert_user",fill = FieldFill.INSERT)
    private String insertUser;


    /**
     * 更新用户
     */
    @TableField(value = "update_user",fill = FieldFill.INSERT_UPDATE)
    private String updateUser;
}
